package com.epam.OOP.cargo;

/**
 * Created with IntelliJ IDEA.
 * User: Yelena_M
 * Date: 04.08.13
 * Time: 23:43
 * To change this template use File | Settings | File Templates.
 */

/*
* Director
* */
public class CargoLoader {

    private CargoBuilder cargoBuilder;

    public void setCargoBuilder(CargoBuilder cb) {
        cargoBuilder = cb;
    }

    public Cargo getCargo() {
        return cargoBuilder.getCargo();
    }

    public void constructCargo() {
        cargoBuilder.createNewCargoProduct();
        cargoBuilder.buildVolume();
        cargoBuilder.buildPrice();
        cargoBuilder.buildWeight();
        cargoBuilder.buildAdditionalParameters();
    }

    public CargoLoader(){

    }
}
